package com.itheima.test1;

import java.util.Scanner;

public class StringFor {
    public static void main(String[] args) {
        Scanner scanner = new Scanner(System.in);

        //录入字符串
        System.out.println("请输入一个字符串:");
        String str = scanner.next();

        //遍历
        for (int i = 0; i < str.length(); i++) {
            char ch = str.charAt(i);
            System.out.println(ch);
        }


    }
}
